﻿<Window x:Class="PageExtractor.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="Contents Spider" Height="700" Width="900">
    <Grid Margin="20,10">
        <Grid.RowDefinitions>
            <RowDefinition Height="120"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="40"/>
        </Grid.RowDefinitions>
        <Border Grid.Row="0" BorderThickness="2" BorderBrush="BurlyWood" Margin="30,10" Padding="10">
            <Grid>
                <Grid.RowDefinitions>
                    <RowDefinition Height="*"/>
                    <RowDefinition Height="*"/>
                </Grid.RowDefinitions>
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="70"/>
                    <ColumnDefinition Width="*"/>
                    <ColumnDefinition Width="40"/>
                </Grid.ColumnDefinitions>
                <Grid.Resources>
                    <Style TargetType="TextBlock">
                        <Setter Property="Margin" Value="10,5"/>
                    </Style>
                    <Style TargetType="TextBox">
                        <Setter Property="Margin" Value="10,5"/>
                    </Style>
                </Grid.Resources>
                <TextBlock Text="Base Url" Grid.Row="0" Grid.Column="0"/>
                <TextBox x:Name="TextUrl" Grid.Row="0" Grid.Column="1"/>
                <Button Content="..." Grid.Row="0" Grid.Column="2" Click="PropertyButton_Click" Margin="5,5"/>
                <TextBlock Text="File Path" Grid.Row="1" Grid.Column="0"/>
                <TextBox x:Name="TextPath" Grid.Row="1" Grid.Column="1"/>
                <Button Content="..." Grid.Row="1" Grid.Column="2" Click="FolderButton_Click" Margin="5,5"/>
            </Grid>
        </Border>        
        <ListView x:Name="ListDownload" Margin="5,20" Padding="5" Grid.Row="1">
            <ListView.View>
                <GridView>
                    <GridViewColumn Header="Download Url" DisplayMemberBinding="{Binding Url}" Width="430"/>
                    <GridViewColumn Header="Saved file" DisplayMemberBinding="{Binding File}" Width="430"/>
                </GridView>
            </ListView.View>
        </ListView>
        <Grid Grid.Row="2">
            <Grid.ColumnDefinitions>
                <ColumnDefinition/>
                <ColumnDefinition/>
            </Grid.ColumnDefinitions>
            <Button x:Name="btnDownload" Content="Download" Click="btnDownload_Click" Grid.Column="0" Margin="30,3"/>
            <Button x:Name="btnStop" Content="Stop" Click="btnStop_Click" Grid.Column="1" Margin="30,3"/>
        </Grid>
    </Grid>
</Window>
